package com.csg.service.service;

import com.csg.api.service.client.DubboDemoClient;
import com.csg.api.service.model.DemoModel;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

/**
 * @author george
 */
@Service
public class DubboDemoService implements DubboDemoClient {

    @Autowired
    private DemoService demoService;

    @Override
    public List<DemoModel> query(DemoModel model) {
        return demoService.query(model);
    }

    @Override
    public DemoModel getInfo(Integer id) {
        return demoService.getInfo(id);
    }

    @Override
    public DemoModel create(DemoModel model) {
        return demoService.create(model);
    }

    @Override
    public DemoModel update(DemoModel model) {
        return demoService.update(model);
    }

    @Override
    public void delete(Integer id) {
        demoService.delete(id);
    }
}
